package cn.chenc.framework.demo.controller;

import cn.chenc.framework.core.model.response.AjaxResult;
import cn.chenc.framework.demo.entity.Role;
import cn.chenc.framework.demo.service.RoleService;
import com.baomidou.mybatisplus.core.metadata.IPage;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 　@description: TODO
 * 　@author secret
 * 　@date 2021/7/31 0:05
 *
 */
@RestController
@RequestMapping("/role")
public class RoleController {

    @Autowired
    private RoleService roleService;

    @GetMapping("/list")
    public AjaxResult queryRolePageList(Role role){
        IPage iPage=roleService.queryRolePageList(role);
        return AjaxResult.success(iPage);
    }
}
